package com.itheima.dao;


import com.itheima.pojo.Dish;
import com.itheima.pojo.DishFlavor;
import com.itheima.vo.DishPageVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author itheima
 * @since 2022-05-03
 */
@Mapper
public interface DishFlavorMapper {
        /**
         * 添加
         * @param list
         * @return
         */
        int insert(List<DishFlavor> list);

        /**
         * 根据id查询
         * @param id
         * @return
         */
        List<DishFlavor> selectById(String id);



        /**
         * 根据菜品id逻辑删除
         * @param ids
         * @return
         */
        int updateIsDeletedById(String[] ids);

        /**
         * 口味下拉
         * @param dishId
         * @return
         */
        List<DishFlavor> selectByDishId(String dishId);

        int deleted(@Param("dishId") String dishId);

}
